package com.rightsidetech.mall.mapper;


import com.rightsidetech.mall.dto.request.BaseInfoPageReq;
import com.rightsidetech.mall.dto.request.OptBaseInfoReq;
import com.rightsidetech.mall.dto.response.BaesInfoDetailResp;
import com.rightsidetech.mall.dto.response.BaseInfoPageResp;
import com.rightsidetech.mall.dto.response.OptBaseInfoPageResp;
import com.rightsidetech.mall.entity.MallBaseInfo;
import com.rightsidetech.mall.entity.MallBaseInfoWithBLOBs;

import java.util.List;

public interface MallBaseInfoMapper {
    int deleteByPrimaryKey(Long id);

    int insert(MallBaseInfoWithBLOBs record);

    int insertSelective(MallBaseInfoWithBLOBs record);

    MallBaseInfoWithBLOBs selectByPrimaryKey(Long id);

    int updateByPrimaryKeySelective(MallBaseInfoWithBLOBs record);

    int updateByPrimaryKeyWithBLOBs(MallBaseInfoWithBLOBs record);

    int updateByPrimaryKey(MallBaseInfo record);

    Long selectCountByCode(String code);

    Long selectCountByName(String commodityName);

    List<BaseInfoPageResp> selectPageList(BaseInfoPageReq req);
    Integer selectPageList_COUNT(BaseInfoPageReq req);

    BaesInfoDetailResp selectInfoDetailById(Long id);

    List<OptBaseInfoPageResp> selectOptPageList(OptBaseInfoReq req);
    Integer selectOptPageList_COUNT(OptBaseInfoReq req);

    Long selectCountByBrandId(Long id);

    Long selectCountByTypeId(Long id);

    List<OptBaseInfoPageResp> selectOptPageIntegral(OptBaseInfoReq req);
}